import java.util.Scanner;
import java.util.Stack;

public class Test11 {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        // 注意 hasNext 和 hasNextLine 的区别
        while (in.hasNext()) {
            String str=in.nextLine();
            Stack<String> stack=new Stack<>();

            String[] s=str.split(" ");
            for(int i=0;i<s.length;i++){
                stack.add(s[i]);
            }
            while(!stack.isEmpty()){
                System.out.print(stack.pop()+" ");
            }
        }
    }








    public static void main01(String[] args) {
        Scanner in = new Scanner(System.in);
        // 注意 hasNext 和 hasNextLine 的区别
        while (in.hasNextInt()) { // 注意 while 处理多个 case
            int n = in.nextInt();
            int m = in.nextInt();
            int a = in.nextInt();
            int b = in.nextInt();

            int x=m%2;
            // 优先二号大礼包
            int y=m/2;
            int sum=0;
            if(y>n){
                sum+= n*b;
            }else{
                sum+=y*b;
                int z=n-y;
                if(z>x){
                    sum+=x*a;
                }else{
                    if(z>=2){
                        sum+=z*a;
                    }
                }
            }

            System.out.println(sum);
        }
    }
}
